package cn.iocoder.yudao.module.crossborder.platform.controller.admin.platformmapping.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.util.*;
import javax.validation.constraints.*;

@Schema(description = "管理后台 - 跨境电商数据映射配置新增/修改 Request VO")
@Data
public class PlatformMappingSaveReqVO {

    @Schema(description = "映射编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "833")
    private Long id;

    @Schema(description = "平台编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "18143")
    @NotNull(message = "平台编号不能为空")
    private Long platformId;

    @Schema(description = "店铺编号（为空表示平台级映射）", example = "7290")
    private Long storeId;

    @Schema(description = "映射类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @NotEmpty(message = "映射类型不能为空")
    private String mappingType;

    @Schema(description = "本地字段", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotEmpty(message = "本地字段不能为空")
    private String localField;

    @Schema(description = "平台字段", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotEmpty(message = "平台字段不能为空")
    private String platformField;

    @Schema(description = "本地值")
    private String localValue;

    @Schema(description = "平台值")
    private String platformValue;

    @Schema(description = "数据类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
    @NotEmpty(message = "数据类型不能为空")
    private String dataType;

    @Schema(description = "转换规则JSON")
    private String transformRule;

    @Schema(description = "是否必填", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "是否必填不能为空")
    private Boolean isRequired;

    @Schema(description = "默认值")
    private String defaultValue;

    @Schema(description = "验证规则")
    private String validationRule;

    @Schema(description = "排序", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "排序不能为空")
    private Integer sort;

    @Schema(description = "状态（0正常 1停用）", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
    @NotNull(message = "状态（0正常 1停用）不能为空")
    private Integer status;

    @Schema(description = "备注", example = "你说的对")
    private String remark;

}